#!/usr/bin/python3.8
# -*- coding: utf-8 -*-
# @Time    : 2021/3/1 11:06
# @Author  : zhaohexin
# @Email   : 1483643520@xxx.com
# @File    : main.py
# @Software: PyCharm
# @FileDescription：启动服务

import uvicorn

from core import create_app

app = create_app()

if __name__ == '__main__':
    # 输出所有路由
    for route in app.routes:
        if hasattr(route, "methods"):
            print({"path": route.path, "name": route.name, "methods": route.methods})
    uvicorn.run(app="main:app", host="127.0.0.1", port=8010, reload=True, debug=True)
